<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%--
  Created by IntelliJ IDEA.
  User: fzh
  Date: 2017/9/17
  Time: 12:09
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<!DOCTYPE html>
<html>
<head>
    <link rel="stylesheet" href="/assets/css/form.css">
    <link rel="stylesheet" href="/assets/css/default.css">
    <meta charset="UTF-8">
    <style type="text/css">
        html, body {
            width: 100%;
            height: 100%;
            font-size: 14px;
        }

        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
        }
    </style>
</head>
<body>
<div class="container">
    <form name="guideForm" class="form" action="<c:url value="/guide/add"/>" method="post" enctype="multipart/form-data">
        <div class="row">
            <div class="col">
                <div class="col-label"><span>标题</span></div>
                <div class="col-content"><input type="text" name="title" title="标题"></div>
            </div>
        </div>
        <div class="row">
            <div class="col">
                <div class="col-label"><span>办理主体</span></div>
                <div class="col-content"><input type="text" name="deptP" title="办理主体" value="${sessionScope.dept.departmentId}" readonly="readonly"/></div>
            </div>
            <div class="col">
                <div class="col-label"><span>责任处室</span></div>
                <div class="col-content">
                    <select name="deptC" title="责任处室">
                        <c:forEach var="childDept" items="${sessionScope.childDepts}">
                            <option value="${childDept.departmentId}"><c:out value="${childDept.deptName}"/></option>
                        </c:forEach>
                    </select>
                </div>
            </div>
        </div>
        <div class="row">
            <div class="col">
                <div class="col-label"><span>办事地址</span></div>
                <div class="col-content"><input type="text" name="addr" title="办事地址"/></div>
            </div>
        </div>
        <div class="row">
            <div class="col">
                <div class="col-label">办理对象</div>
                <div class="col-content">
                    <select name="obj" title="办理对象">
                        <option value="0">个人</option>
                        <option value="1">企业</option>
                        <option value="2">个人和企业</option>
                    </select>
                </div>
            </div>
            <div class="col">
                <div class="col-label">行使层级</div>
                <div class="col-content">
                    <select name="hierarchy" title="行使层级">
                        <option value="1">乡（镇、办)</option>
                        <option value="2">县（市、区），乡（镇、街道办）</option>
                    </select>
                </div>
            </div>
        </div>
        <div class="row">
            <div class="col">
                <div class="col-label">权力来源</div>
                <div class="col-content">
                    <input class="text-input" type="text" name="powerFrom" list="power_from_list" title="权力来源">
                    <datalist id="power_from_list">
                        <option value="宪法赋予">宪法赋予</option>
                        <option value="行政权力">行政权力</option>
                    </datalist>
                </div>
            </div>
        </div>
        <div class="row">
            <div class="col">
                <div class="col-label">承诺期限</div>
                <div class="col-content">
                    <input class="text-input" type="text" name="promiseTimeLimit" list="promise_time_limit_list"
                           title="承诺期限">
                    <datalist id="promise_time_limit_list">
                        <option value="10">10 天</option>
                        <option value="20">20 天</option>
                        <option value="30">30 天</option>
                    </datalist>
                </div>
            </div>
            <div class="col">
                <div class="col-label">承诺收费</div>
                <div class="col-content">
                    <select name="charge" title="承诺收费">
                        <option value="0">不收费</option>
                        <option value="1">收费</option>
                        option
                    </select>
                </div>
            </div>
        </div>
        <div class="row">
            <div class="col">
                <div class="col-label"><span>服务主题</span></div>
                <div class="col-content">
                    <input type="text" name="serviceSubject" title="服务主题">
                </div>
            </div>
            <div class="col">
                <div class="col-label"><span>结果文件</span></div>
                <div class="col-content">
                    <input type="text" name="resultFile" title="结果文件">
                </div>
            </div>
        </div>
        <div class="row">
            <div class="col">
                <div class="col-label"><span>咨询电话</span></div>
                <div class="col-content">
                    <input type="text" name="consultationTel" title="咨询电话">
                </div>
            </div>
            <div class="col">
                <div class="col-label"><span>投诉电话</span></div>
                <div class="col-content">
                    <input type="text" name="complaintTel" title="投诉电话">
                </div>
            </div>
        </div>
        <div class="row-large">
            <div class="col">
                <div class="col-label on-top"><span>阅读须知</span></div>
                <div class="col-content">
                    <textarea name="notice" title="阅读须知">无</textarea>
                </div>
            </div>
        </div>
        <div class="row-large">
            <div class="col">
                <div class="col-label on-top"><span>办事依据</span></div>
                <div class="col-content">
                    <textarea name="dealBasis" title="办事依据">无</textarea>
                </div>
            </div>
        </div>
        <div class="row-large">
            <div class="col">
                <div class="col-label on-top"><span>申请条件</span></div>
                <div class="col-content">
                    <textarea name="applicationCondition" title="申请条件">无</textarea>
                </div>
            </div>
        </div>
        <div class="row-large">
            <div class="col">
                <div class="col-label on-top"><span>申报材料</span></div>
                <div class="col-content">
                    <textarea name="material" title="申报材料">无</textarea>
                </div>
            </div>
        </div>
        <div class="row-large">
            <div class="col">
                <div class="col-label on-top"><span>追责情形</span></div>
                <div class="col-content">
                    <textarea name="callSituation" title="追责情形">无</textarea>
                </div>
            </div>
        </div>
        <div class="row-large">
            <div class="col">
                <div class="col-label on-top"><span>追责依据</span></div>
                <div class="col-content">
                    <textarea name="callBasis" title="追责依据">无</textarea>
                </div>
            </div>
        </div>
        <div class="row">
            <div class="col">
                <div class="col-label"><span>办理流程图</span></div>
                <div class="col-content">
                    <input type="file" accept="image/png" name="file"/>
                </div>
            </div>
            <div class="col">
                <div class="col-label"><span>支持在线申报</span></div>
                <div class="col-content">
                    <input style="width: 18px;" type="radio" name="online" onclick="console.log(this.value)" value="1" checked
                           title="支持">是&nbsp;&nbsp;&nbsp;
                    <input style="width: 18px;" type="radio" name="online" onclick="console.log(this.value)" value="2"
                           title="不支持">否
                </div>
            </div>
        </div>
        <br>
        <div class="row">
            <div class="col"></div>
            <div class="col">
                <div style="width: 100%;text-align: center;" class="btn btn-success" onclick="check()"><span>提交</span></div>
            </div>
            <div class="col"></div>
        </div>
    </form>
</div>
<script type="text/javascript">
    function check() {
        document.guideForm.submit();
    }
</script>
</body>
</html>
